
# Makefile
# David Grant, 2004

CC=m68k-elf-gcc
CXX=m68k-elf-g++
CFLAGS=-O0 -Wall -m5200 -nostdlib
NM=m68k-elf-nm
LD=m68k-elf-gcc
AS=m68k-elf-as
AR=m68k-elf-ar
ARFLAGS=
OBJCPY=m68k-elf-objcopy
ASM=
LDFLAGS = -Tmcf5307.ld -Wl,-Map=rtx.map

# Note, GCC builds things in order, it's important to put yhe
#  ASM first, so that it is located at the beginning of our program.
rtx.s19: *.c *.s
	$(CC) $(CFLAGS) $(LDFLAGS) -o rtx.o $(ASM) *.s *.c
	$(OBJCPY) --output-format=srec rtx.o rtx.s19
	
no-assemble:
	$(CC) $(CFLAGS) $(LDFLAGS) -S *.s *.c
	

clean:
	rm -f *.s19 *.o *.map







